<?
ob_start();
session_start();
include("../conf/config.php");
include("../conf/database.php");
include("../conf/tools.php");

$curTime=getIndianDateTime();
$commit_id=$_GET["commit_id"];
$mode=$_GET["mode"]; 

foreach($_POST as $key => $value) { $arr_data[$key]=$value;}
foreach($arr_data as $key => $value) { $arr_data[$key]=addslashes($value); }

$arr_data["rec_status"]=1;


if($commit_id>0){

update_qry("bkitc_member_commitment",$arr_data,"commit_id=".$commit_id);


}
else{

	$commit_id=insert_qry("bkitc_member_commitment",$arr_data);
	

}



header("location:edit_commitment.php?mode=edit&commit_id=".$commit_id);
?>



